We develop a Bayesian nonparametric model for reconstructing magnetic resonance images (MRI) from highly undersampled k-space data. Our model uses the beta process as a nonparametric prior for dictionary learning, in which an image patch is a sparse combination of dictionary elements. The size of the dictionary and the patch-specific sparsity pattern is inferred from the data, in addition to all dictionary learning variables. Dictionary learning is performed as part of the image reconstruction process, and so is tailored to the MRI being considered. In addition, we investigate a total variation penalty term in combination with the dictionary learning model. We derive a stochastic optimization algorithm based on Markov Chain Monte Carlo (MCMC) sampling for the Bayesian model, and use the alternating direction method of multipliers (ADMM) for efficiently performing total variation minimization. We present empirical results on several MRI, which show that the proposed regularization framework can improve reconstruction accuracy over other methods.